﻿' Teacher class
'
' This class provides get and set methods for IdNumber, Password,
' Program, PClassTime, and Department. 
' This class inherits from the Person class.
'
' By Taji Abdullah 6/30/08

Public Class Teacher
    Inherits Person       ' Base class

    'Class variables
    Private teacherNumber As Integer        ' To hold the teacher id number
    Private tPassword As String             ' To hold the teachers password
    Private tProgram As String              ' To hold the teachers program instructing in
    Private perferClassTime As String       ' To hold the teachers perfered class time
    Private tdepartment As String           ' To hold the teachers department

    ' Constructor
    Public Sub New()
        Debug.WriteLine("Teacher object being created.")
        teacherNumber = 0
        tPassword = " "
        tProgram = " "
        tProgram = " "
        tdepartment = " "
    End Sub

    ' IdNumber get and set methods.
    Public Property IdNumber() As Integer
        Get
            Return teacherNumber
        End Get
        Set(ByVal value As Integer)
            teacherNumber = value
        End Set
    End Property

    ' Password get and set methods.
    Public Property Password() As String
        Get
            Return tPassword
        End Get
        Set(ByVal value As String)
            tPassword = value
        End Set
    End Property

    ' Program get and set methods.
    Public Property Program() As String
        Get
            Return tPassword
        End Get
        Set(ByVal value As String)
            tPassword = value
        End Set
    End Property

    ' PClassTime get and set methods.
    Public Property PClassTime() As String
        Get
            Return perferClassTime
        End Get
        Set(ByVal value As String)
            perferClassTime = value
        End Set
    End Property

    ' Department get and set methods.
    Public Property Department() As String
        Get
            Return tdepartment
        End Get
        Set(ByVal value As String)
            tdepartment = value
        End Set
    End Property

    ' Destructor
    Public Overloads Sub Clear()
        teacherNumber = 0
        tPassword = " "
        tProgram = " "
        tProgram = " "
        tdepartment = " "
    End Sub

End Class